package br.com.management.mentor.app.components.messageextractors;

import org.springframework.security.core.AuthenticationException;

import br.com.management.mentor.app.components.ExceptionMessageExtractor;

public class AuthenticationExceptionMessageExtractor implements ExceptionMessageExtractor {

	@Override
	public boolean canHandle( Exception e ) {
		return AuthenticationException.class.isAssignableFrom( e.getClass() );
	}

	@Override
	public String getMessage( Exception e ) {
		return e.getMessage();
	}
	
}